package spring.boot.notes.jacquesh.event2.project.listenters;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import spring.boot.notes.jacquesh.event.project.event.RainEvent;
import spring.boot.notes.jacquesh.event.project.event.SnowEvent;

@Component
public class WeatherRunnerListenster {
	@Autowired
	private  WeatherEventMultister weatherEventMultister;
	public  void snow(){
		weatherEventMultister.multicastEvent(new SnowEvent());
	}
	public  void rain(){
		weatherEventMultister.multicastEvent(new RainEvent());
	}
}
